<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>文字闪动特效</title>
</head>
<body>
    <p>
        <span id="n">n</span>
        <span id="e">e</span>
        <span id="o">o</span>
        <span id="n2">n</span>
      </p>
</body>
<style>
    @import url('https://fonts.googleapis.com/css2?family=Warnes&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Dancing+Script&display=swap');

:root {
    --color : #42fff6
}

body {
	height: 100vh;
	display: flex;
	align-items: center;
	justify-content: center;
	background-color: #000000;
}

p {
  background: none;
  color: #999;
  font-family: 'Dancing Script', 'Warnes', cursive;
  font-size: 200px;
  letter-spacing: -26px;
  cursor: pointer;
}

p:hover span {
  animation: flicker 1s linear forwards;
}

p:hover #e {
  animation-delay: .2s;
}

p:hover #o {
  animation-delay: .5s;
}

p:hover #n2 {
  animation-delay: .6s;
}

@keyframes flicker {
  0% {
    color: #333;
  }
  5%, 15%, 25%, 30%, 100% {
    color: #fff;
    text-shadow: 
      0px 0px 5px var(--color),
      0px 0px 10px var(--color),
      0px 0px 20px var(--color),
      0px 0px 50px var(--color);
      
  }
  10%, 20% {
    color: #333;
    text-shadow: none;
  }
}


</style>
</html>